import os,shutil   #shutil os模块的补充os,os.path,shutil

#help(os)
#help(shutil)
print([x for x in os.listdir('.') if os.path.isdir(x)])
print([x for x in os.listdir('.') if os.path.isfile(x) and os.path.splitext(x)[1]==".py"])
